package com.rraj.apiversion;

import org.springframework.boot.autoconfigure.web.WebMvcRegistrationsAdapter;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping;

/**
 * 自定义注册类
 *
 * @author WangSheng
 * @date 2017/06/20
 */
@Configuration
public class MyWebMvcRegistrationsAdapter extends WebMvcRegistrationsAdapter {
    /**
     * 注册自定义的RequestMappingHandlerMapping
     * @return RequestMappingHandlerMapping
     */
    @Override
    public RequestMappingHandlerMapping getRequestMappingHandlerMapping() {
        return new CustomRequestMappingHandlerMapping();
    }
}
